// 头部菜单
layui.use(["jquery", "dropdown"], function () {
    let $ = layui.$
    let dropdown = layui.dropdown

    /**
     * 下拉菜单
     */
    dropdown.render({
        elem: "#header-menu",
        content: $(".layui-header .layui-nav").html(),
        className: "layui-nav layui-bg-gray layui-bg-light",
        style: "position: absolute;display: flex;flex-direction: column;",
        ready: function (elemPanel, elem) {
            $(elem).css("display", "inline-block");
            $(elem).css("transform", "rotate(-90deg)");
        },
        close: function (elem) {
            $(elem).css("transform", "rotate(0deg)");
        }
    });
})